@include("user.head")
	<!-- 公共头部 -->

	<div id="content_list">

			<!-- 分类 -->
			<div class="category">
				<div class="cate_top">
				</div>
			</div>

			<ul class="nav nav-tabs">
			<li class="active"><a aria-expanded="true" href="#project" data-toggle="tab">收藏的项目</a></li>
			  <li class=""><a aria-expanded="false" href="#product" data-toggle="tab">收藏的设备</a></li>
			  <li class=""><a aria-expanded="false" href="#tech" data-toggle="tab">收藏的技术</a></li>
			</ul>
			<div id="myTabContent" class="tab-content">
			  	<div class="tab-pane fade active in" id="project">
			 	</div>
			 	<div class="tab-pane fade" id="product">
			  	</div>
			  	<div class="tab-pane fade" id="tech">
			  	</div>
			</div>
			</div>
			</div>
			</div>
	</div>
@include("user.footer")
@include("user.common")

</body>
<script type="text/html" id="projectTemp">
	{%each list as value index}
  		<div class="col-xs-3">
  			<div class="col-xs-12 thumbnail">
  				<a href="<%url('industry/project/detail?pid={%value.project.id}')%>">
  					<img src="<%url('images')%>/{%value['project']['uid']}/<%env('PROJECT_DIR')%>/{%value['project']['image']}" style="width:200px;height:200px;" alt="" />
  					<span class="col-xs-12">
  						<h5>{%value["project"]["name"]}</h5>
  					</span>
  					<span class="col-xs-12 product_des">
  						{%truncateText(value.project.description, 25)}
  					</span>
  					<span class="col-xs-12 product_btns">
  						<button type="button" class="btn btn-info fl btn wanna_do" pid="">我要做</button>
  					</span>
  				</a>
  			</div>
  		</div>
	{%/each}
</script>
<script type="text/javascript">
	$.get("<%url('collect/get_project')%>", function(data){
		console.log(data);
		if(data.success){
			var html = template("projectTemp",{list:data.data});
			$("#project").html(html);
		}
	})
</script>
<script type="text/html" id="productTemp">
	{%each list as value index}
  		<div class="col-xs-3">
			<div class="col-xs-12 thumbnail">
				<a href="<%url('industry/device/detail?did={%value.device.id}')%>">
					<img src="<%url('images')%>/{%value['device']['uid']}/<%env('DEVICE_DIR')%>/{%value['device']['image']}" height="200" width="200" alt="" />
					<span class="col-xs-12">
						<h5>{%value.device.name}</h5>
					</span>
					<span class="col-xs-12 product_des">
							{%truncateText(value.device.description, 25)}
					</span>
					<span class="col-xs-12 device_des">
						￥{%value.device.minimize_price} - ￥{%value.device.maximize_price}
					</span>
				</a>
			</div>
		</div>
	{%/each}
</script>
<script type="text/javascript">
	$.get("<%url('collect/get_device')%>", function(data){
		var html = template("productTemp",{list:data.data});
		$("#product").html(html);
	})
</script>

<script type="text/html" id="techTemp">
{%each list as value index}
<div class="col-xs-3">
  	<div class="col-xs-12 rec_project thumbnail">
  		<a href="<%url('industry/tech/detail?tid={%value.tech.id}')%>">
	  		<img src="<%url('images')%>/{%value['tech']['uid']}/<%env('TECH_DIR')%>/{%value['tech']['image']}" width="200" alt="" />
	  		<span class="col-xs-12">
	  			<h5>{%value.tech.tech_name}</h5>
	  		</span>
	  		<span class="col-xs-12 product_des">
	  			{%truncateText(value.tech.description, 25)}
			</span>
		</a>
  	</div>
</div>
{%/each}
</script>
<script type="text/javascript">
	$.get("<%url('collect/get_tech')%>", function(data){
		var html = template("techTemp",{list:data.data});
		$("#tech").html(html);
	})
</script>
</html>
